redis 套件的 Property 'on' does not exist on type 'RedisClientType'


再用 typescript 開發時發現 client.on('error', (err) => console.log('Redis Client Error', err)); 會跳出錯誤 Property 'on' does not exist on type 'RedisClientType' ,加上 npm i -D @types/node 就解決了

#TypeScript #VS Code #Redis #nodejs #ts #js #Node






你可能感興趣的文章

APP發版小知識

APP發版小知識

C# class, object, method, constructors, getter, setter, static

C# class, object, method, constructors, getter, setter, static

# 〈 Diffusion Model 論文研究與實作心得 Part.2 〉 U-Net 模型架構介紹與實作

# 〈 Diffusion Model 論文研究與實作心得 Part.2 〉 U-Net 模型架構介紹與實作






留言討論